package sist.erp.db.Main;

import java.util.List;

import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;

public class MessageManager extends SqlMapClientDaoSupport {
	public void messageSend(MessageVO vo) throws Exception{
		getSqlMapClientTemplate().insert("messageSend", vo);
	}
	
	public Integer messageCount(int emp_no) throws Exception{
		return (Integer)getSqlMapClientTemplate().queryForObject("messageCount",emp_no);
	}

	public List messageAllData(int emp_no) throws Exception{
		return getSqlMapClientTemplate().queryForList("messageAllData",emp_no);
	}
	
	public void messageDelete(int message_no) throws Exception{
		getSqlMapClientTemplate().delete("messageDelete", message_no);
	}
	
	public MessageVO messageContent(int message_no) throws Exception{
		return (MessageVO)getSqlMapClientTemplate().queryForObject("messageContent", message_no);
	}

}
